<?php
namespace Home\Controller;
use Think\Controller;
class FrontController extends Controller {
    public function index(){
    	$catalogs=M("product_catalog")->where('parent_id=0')->select();
    	$products=M("product")->where('hot=1')->limit(4)->select();
    	$notes=M("article")->where('type=0')->limit(5)->select();
    	$news=M("article")->where('type=1')->limit(5)->select();
    	$catalogs=$this->assign('catalogs',$catalogs);
    	$products=$this->assign('products',$products);
    	$notes=$this->assign('notes',$notes);
    	$news=$this->assign('news',$news);
		$this->display();
    }
}